
<div id="wrapper">    
    <div class="pageContent">

	<div class="themeHeader">
		<div class="title">Yoke for Vert.x</div>
		<div class="subTitle paleYellow">An easy way to build web applications</div>
	</div>

<br/>

	<div class="codePreview">
		<div class="title">Templates</div>
	    <div class="code" style="color: #E0E2E4;background-color: #293134;"><span class="orange bold">Groovy: </span>
<span>Using the standard Groovy Template Engine is very straightforwards and it's fully integrated with the whole Groovy experience.</span>

<span class="orange bold">Layout Support: </span>
<span>Render both the main template and the layout: place the <span class="blue">&#36;&#123;TemplateBody&#125;</span> placeholder inside the layout template and Yoke will replace it with the main template body.</span>
 
<span class="orange bold">Template Caching: </span>
<span>Yoke caches the template files in memory and only reloads them if the file has changed or the cache has expired.</span></div>
	</div>
	
<br/>

<div class="codePreview">
		<div class="title">Inside the router</div>
	    <div class="code" style="color: #E0E2E4;background-color: #293134;"><span class="orange bold">No layout: </span>
<span>request.response.render 'template.html', next</span>

<span class="orange bold">With layout: </span>
<span>request.response.render 'bodyOnly.html','layout.html', next</span>
	</div>
</div>
<br/>

<div class="codePreview">
		<div class="title">Inside the template</div>
	    <div class="code" style="color: #E0E2E4;background-color: #293134;"><span class="orange bold">Iterations: </span>
<span>  <% 3.times { %>
    Hello World!
  <% } %></span>

<span class="orange bold">Conditionals: </span>
<span>  <% if (session != null) { %>
    My session id is ${session.id}
  <% } else println "No session created." %></span>
	</div>	
</div>


	</div><!-- END div id="wrapper" -->
</div><!-- END div class="page-content" -->
